#
# Be sure to run `pod lib lint SQNetworkLibrary.podspec' to ensure this is a
# valid spec before submitting.
#
# Any lines starting with a # are optional, but their use is encouraged
# To learn more about a Podspec see https://guides.cocoapods.org/syntax/podspec.html
# pod lib lint --sources='http://git.17gwx.com/iOS_lib/Lib.git,http://git.17gwx.com/iOS/SQSpecs.git,https://gitee.com/sqkb-ios/sqspecs.git' --allow-warnings --verbose

Pod::Spec.new do |s|
  s.name             = 'SQNetworkLibrary'
  s.version          = '0.1.5'
  s.summary          = 'jxz SQNetworkLibrary'

# This description is used to generate tags and improve search results.
#   * Think: What does it do? Why did you write it? What is the focus?
#   * Try to keep it short, snappy and to the point.
#   * Write the description between the DESC delimiters below.
#   * Finally, don't worry about the indent, CocoaPods strips it!

  s.description      = <<-DESC
TODO: jxz SQNetworkLibrary test
                       DESC

  s.homepage         = 'http://git.17gwx.com/iOS_lib/SQNetworkLibrary'
  # s.screenshots     = 'www.example.com/screenshots_1', 'www.example.com/screenshots_2'
  s.license          = { :type => 'MIT', :file => 'LICENSE' }
  s.author           = { 'laohei' => 'laohei@ibantang.com' }
  s.source           = { :git => 'http://git.17gwx.com/iOS_lib/SQNetworkLibrary.git', :tag => s.version.to_s }
  # s.social_media_url = 'https://twitter.com/<TWITTER_USERNAME>'

  s.ios.deployment_target = '9.0'

  
  s.source_files = 'SQNetworkLibrary/Classes/OutSetHeader/**/*'
  s.subspec 'TrackNetwork' do |ss|
     ss.source_files = 'SQNetworkLibrary/Classes/Network/**/*'
     ss.ios.dependency 'AFNetworking', '~> 3.2.1'
     ss.ios.dependency 'BTSnappy', '0.1.1'
     ss.ios.dependency 'BTNetworkReachabilityManager'
   end
  
  s.subspec 'SQBusinessNetwork' do |bus|
      bus.source_files = 'SQNetworkLibrary/Classes/Buswork/**/*'
      bus.ios.dependency 'BTNetworking', '~> 1.0.1'
      bus.ios.dependency 'YYModel'
      bus.ios.dependency 'SQToolsLibrary'
      bus.ios.dependency 'Masonry'
      bus.ios.dependency 'MBProgressHUD'
      bus.ios.dependency 'AFNetworking', '~> 3.2.1'
  end
  
  s.dependency 'SQMediator'
  # s.resource_bundles = {
  #   'SQNetworkLibrary' => ['SQNetworkLibrary/Assets/*.png']
  # }
  
  
  
  if ENV['push'] == "1"
      puts '-----------------------提交本地pod---------------------------------------'
      dev_url = "./"+s.name
      puts Dir.pwd
      system 'git add .'
      system "git commit -m 'pod 提交'"
      system 'git push origin master'
      puts '--------------------------结束-----------------------------------------'
  end

end
